package com.njdj.gps.kernel.service.impl;

import java.util.List;
import java.util.Map;

import com.njdj.gps.common.page.PageList;
import com.njdj.gps.common.page.PageProperty;
import com.njdj.gps.common.util.PageUtil;
import com.njdj.gps.kernel.service.impl.BaseServiceImpl;
import com.njdj.gps.kernel.dao.ISeTaskDao;
import com.njdj.gps.kernel.entity.SeTask;
import com.njdj.gps.kernel.service.ISeTaskService;

/**
 * @Description:实现类
 * @author harry
 * @version 1.0
 */
public class SeTaskServiceImpl extends BaseServiceImpl<SeTask,ISeTaskDao> implements ISeTaskService {

	public PageList<SeTask> listSplitTaskView(PageProperty pp) {
		int count = this.getBaseDao().getSplitTaskViewCount(pp);
		int start = PageUtil.getStart(pp.getNpage(), count,  pp.getNpagesize());
		int end = PageUtil.getEnd(pp.getNpage(), count, pp.getNpagesize());
		pp.putParamMap("startrow", start);
		pp.putParamMap("endrow", end);
		PageList<SeTask> pageList = new PageList<SeTask>(pp, count, this.getBaseDao().listSplitTaskView(pp));
		return pageList;
	}

	public List<SeTask> listLastModel(Map<String, Object> param) {
		return this.getBaseDao().listLastModel(param);
	}

}
